package com.plian.system.entity.pf;

import com.baomidou.mybatisplus.annotation.FieldStrategy;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.plian.Tools.DateUtil;
import com.plian.system.mybatis.base.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * @Author: Take-off
 * @Description: TODO
 * @Date: 2023/1/9 11:12 AM
 * @Version: 1.0
 **/
@Data
@TableName("pf_base_business_indicators_old")
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "BaseBusinessIndicatorsOld 对象", description = "经营业绩考核指标主表-旧")
public class BaseBusinessIndicatorsOld extends BaseEntity {

    /**
     * 单据编码
     */
    @ApiModelProperty(value = "单据编码")
    private String code;

    /**
     * 填报年度
     */
    @ApiModelProperty(value = "填报年度")
    private String fillingYear;

    /**
     * 填报单位
     */
    @ApiModelProperty(value = "填报单位")
    private String fillingUnitId;

    /**
     * 审批人
     */
    @ApiModelProperty(value = "审批人")
    private String approvedUser;

    /**
     * 审批时间
     */
    @DateTimeFormat(pattern = DateUtil.PATTERN_DATETIME)
    @JsonFormat(pattern = DateUtil.PATTERN_DATETIME)
    @ApiModelProperty(value = "审批时间")
    private Date approvedTime;

    /**
     * 审批意见
     */
    @ApiModelProperty(value = "审批意见")
    private String approvedOpinion;

    /**
     * 流程实例id
     * 单据类型
     */
    @ApiModelProperty(value = "单据类型")
    private String formType;

    @TableField(exist = false)
    @ApiModelProperty(value = "子表")
    private List<BusinessIndicatorsOld> businessIndicators;

    /**
     * 党建综合指标 指标权重
     */
    @TableField(value = "party_indicators_weight",updateStrategy = FieldStrategy.IGNORED)
    @ApiModelProperty(value = "党建综合指标 指标权重")
    private BigDecimal partyIndicatorsWeight;

    /**
     * 特定工作任务说明
     */
    @ApiModelProperty(value = "特定工作任务说明")
    private String instructions;
}
